package com.woniuxy.user.mapper;

import com.woniuxy.entity.Role;
import com.woniuxy.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface RoleMapper {

    List<Role> selectAllRoles();

    Role selectById(int id);

    List<Role> selectByName(String rolename);

    int insertRole(Role role);

    void updateRole(Role role);

    void deleteRole(int id);

    void insertPermission(@Param("rid") int rid,@Param("pid") int pid);

    void deletePermission(int rid);

}
